<?php 
namespace app\admin\validate;
use think\Validate;

class Brand extends Validate{
	protected $rule=[
		'brand_name'	=>'require|unique:brand',
		'brand_url'		=>'url',
		'brand_description'=>'min:10',
	];

	protected $message=[
		'brand_name.require'	=>'品牌名称必须填写！',
		'brand_name.unique'	=>'品牌名称不能重复！',
		'brand_url'		=>'请输入正确的网址！',
		'brand_description'=>'品牌描述最少输入10个字符',
	];

	// protected $scene=[
	// 	'add'	=>['brand_name'],
	// 	'edit'	=>['brand_url','brand_description'],
	// ];
}